using System;
using System.Collections.Generic;
using System.Text;

using NHibernate;
using Zwms.Data.Base;
using System.Runtime.Serialization;

namespace Zwms.Data.BusinessObjects
{
    [DataContract]
    public partial class SysAccount : BusinessBase<string>
    {

        #region Declarations

        private string _userName = String.Empty;
        private string _userRole = String.Empty;
        private string _password = String.Empty;
        private string _isLocked = String.Empty;
        private string _createDate = String.Empty;
        private string _createTime = String.Empty;
        private string _lastLoginDate = String.Empty;
        private string _lastLoginTime = String.Empty;
        private string _lastLogoutDate = String.Empty;
        private string _lastLogoutTime = String.Empty;
        private string _departmentCode = String.Empty;
        private string _departmentName = String.Empty;
        private string _warehouseCode = String.Empty;
        private string _warehouseName = String.Empty;
        private string _remark = String.Empty;



        #endregion

        #region Constructors

        public SysAccount() { }

        #endregion

        #region Methods

        public override int GetHashCode()
        {
            System.Text.StringBuilder sb = new System.Text.StringBuilder();

            sb.Append(this.GetType().FullName);
            sb.Append(_userName);
            sb.Append(_userRole);
            sb.Append(_password);
            sb.Append(_isLocked);
            sb.Append(_createDate);
            sb.Append(_createTime);
            sb.Append(_lastLoginDate);
            sb.Append(_lastLoginTime);
            sb.Append(_lastLogoutDate);
            sb.Append(_lastLogoutTime);
            sb.Append(_departmentCode);
            sb.Append(_departmentName);
            sb.Append(_warehouseCode);
            sb.Append(_warehouseName);
            sb.Append(_remark);

            return sb.ToString().GetHashCode();
        }

        #endregion

        #region Properties
        [DataMember]
        public virtual string UserName
        {
            get { return _userName.TrimEnd(); }
            set
            {
                _userName = value;
            }
        }

        [DataMember]
        public virtual string UserRole
        {
            get { return _userRole.TrimEnd(); }
            set
            {
                _userRole = value;
            }
        }

        [DataMember]
        public virtual string Password
        {
            get { return _password.TrimEnd(); }
            set
            {
                _password = value;
            }
        }

        [DataMember]
        public virtual string IsLocked
        {
            get { return _isLocked.TrimEnd(); }
            set
            {
                _isLocked = value;
            }
        }

        [DataMember]
        public virtual string CreateDate
        {
            get { return _createDate.TrimEnd(); }
            set
            {
                _createDate = value;
            }
        }

        [DataMember]
        public virtual string CreateTime
        {
            get { return _createTime.TrimEnd(); }
            set
            {
                _createTime = value;
            }
        }

        [DataMember]
        public virtual string LastLoginDate
        {
            get { return _lastLoginDate.TrimEnd(); }
            set
            {
                _lastLoginDate = value;
            }
        }

        [DataMember]
        public virtual string LastLoginTime
        {
            get { return _lastLoginTime.TrimEnd(); }
            set
            {
                _lastLoginTime = value;
            }
        }

        [DataMember]
        public virtual string LastLogoutDate
        {
            get { return _lastLogoutDate.TrimEnd(); }
            set
            {
                _lastLogoutDate = value;
            }
        }

        [DataMember]
        public virtual string LastLogoutTime
        {
            get { return _lastLogoutTime.TrimEnd(); }
            set
            {
                _lastLogoutTime = value;
            }
        }

        [DataMember]
        public virtual string DepartmentCode
        {
            get { return _departmentCode.TrimEnd(); }
            set
            {
                _departmentCode = value;
            }
        }

        [DataMember]
        public virtual string DepartmentName
        {
            get { return _departmentName.TrimEnd(); }
            set
            {
                _departmentName = value;
            }
        }

        [DataMember]
        public virtual string WarehouseCode
        {
            get { return _warehouseCode.TrimEnd(); }
            set
            {
                _warehouseCode = value;
            }
        }

        [DataMember]
        public virtual string WarehouseName
        {
            get { return _warehouseName.TrimEnd(); }
            set
            {
                _warehouseName = value;
            }
        }

        [DataMember]
        public virtual string Remark
        {
            get { return _remark.TrimEnd(); }
            set
            {
                _remark = value;
            }
        }

        #endregion
    }
}